package com.zgjkhis.modules.system.service.impl;

import com.zgjkhis.common.service.impl.BaseServiceImpl;
import com.zgjkhis.modules.system.domain.Region;
import com.zgjkhis.modules.system.domain.vo.RegionTree;
import com.zgjkhis.modules.system.domain.vo.RegionVO;
import com.zgjkhis.modules.system.service.RegionService;
import com.zgjkhis.modules.system.service.mapper.RegionMapper;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Propagation;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;
import java.util.Map;

// 默认不使用缓存
//import org.springframework.cache.annotation.CacheConfig;
//import org.springframework.cache.annotation.CacheEvict;
//import org.springframework.cache.annotation.Cacheable;

/**
 * @Author yzq
 * @Description 渠道
 * @Date 2021/6/23 9:47
 * @Param
 * @return
 **/
@Service
//@CacheConfig(cacheNames = "user")
@Transactional(propagation = Propagation.SUPPORTS, readOnly = true, rollbackFor = Exception.class)
public class RegionServiceImpl extends BaseServiceImpl<RegionMapper, Region> implements RegionService {

    @Override
    public List<RegionVO> lazyList(String parentCode, Map<String, Object> param) {
        return baseMapper.lazyList(parentCode, param);
    }

    @Override
    public List<RegionTree> lazyTree(String parentCode, Map<String, Object> param) {
        return baseMapper.lazyTree(parentCode, param);
    }


}
